Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

buffer: remove unreachable code #27445

Closed
wants to merge 1 commit into from
Closed

Conversation

Trott
Copy link
Member

@Trott Trott commented Apr 28, 2019

Remove unreachable code from lib/buffer.js.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines

Remove unreachable code from lib/buffer.js.
@nodejs-github-bot
Copy link
Collaborator

@nodejs-github-bot nodejs-github-bot added the buffer Issues and PRs related to the buffer subsystem. label Apr 28, 2019
@Trott
Copy link
Member Author

Trott commented Apr 28, 2019

The check for offset === undefined will always be false due to the earlier check for offset === undefined in the function. Coverage reports are consistent with this, showing the if block never executing.

@nodejs-github-bot
Copy link
Collaborator

nodejs-github-bot commented Apr 28, 2019

CI: https://ci.nodejs.org/job/node-test-pull-request/22752/ (:white_check_mark:)

@Trott Trott added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Apr 28, 2019
@Trott
Copy link
Member Author

Trott commented Apr 30, 2019

Landed in 524dd46

@Trott Trott closed this Apr 30, 2019
Trott added a commit to Trott/io.js that referenced this pull request Apr 30, 2019
Remove unreachable code from lib/buffer.js.

PR-URL: nodejs#27445
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Yongsheng Zhang <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
targos pushed a commit that referenced this pull request Apr 30, 2019
Remove unreachable code from lib/buffer.js.

PR-URL: #27445
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Yongsheng Zhang <[email protected]>
Reviewed-By: Ruben Bridgewater <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
@targos targos mentioned this pull request May 6, 2019
@Trott Trott deleted the unreachable-buffer branch January 13, 2022 22:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. buffer Issues and PRs related to the buffer subsystem.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants